package thoven.achievement.net.jsonutil.toolwindow

import com.intellij.openapi.project.Project
import com.intellij.openapi.wm.ToolWindow
import com.intellij.openapi.wm.ToolWindowFactory
import com.intellij.ui.content.ContentFactory

/**
 * JSON 工具窗口工厂
 */
class JsonToolWindowFactory : ToolWindowFactory {
    
    override fun createToolWindowContent(project: Project, toolWindow: ToolWindow) {
        val jsonToolWindow = JsonToolWindowPanel(project)
        val contentFactory = ContentFactory.getInstance()
        val content = contentFactory.createContent(jsonToolWindow, "", false)
        toolWindow.contentManager.addContent(content)
    }
}

